<%--
  Created by IntelliJ IDEA.
  User: MSI-CN
  Date: 2020/11/30
  Time: 17:25
  To change this template use File | Settings | File Templates.
--%>
<!--
@name:
@description:
@author: lzy
@title: 天王盖地虎!!!
@time:  2021-01-11 15:11:54
-->
<% String path=request.getContextPath(); %>
<%@ page contentType="text/html;charset=UTF-8" language="java" pageEncoding="utf-8" isErrorPage="true" %>
<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <title></title>
</head>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@4.5.0/dist/css/bootstrap.min.css" integrity="sha384-9aIt2nRpC12Uk9gS9baDl411NQApFmC26EwAOH8WgZl5MYYxFfc+NcPb1dKGj7Sk" crossorigin="anonymous">

<script type="text/javascript">
    function login(){
        var username = document.getElementById("username").value;
        var password= document.getElementById("password").value;
        if((username=="")){
            window.alert("用户名不能为空！");
        }else if(password==""){
            window.alert("密码不能为空！");
        }else {
            window.alert("验证中~");
            document.getElementById("form").submit();
        }
    }
</script>
<body>
<div class="modal-dialog" style="margin-top: 10%;">
    <div class="modal-content">
        <div class="modal-header">
            <h4 class="modal-title text-center" id="myModalLabel">登录</h4>
        </div>
        <form method="post" action="<%=path%>/loginServlet" id="form">
            <div class="modal-body" id = "model-body">
                <div class="form-group">
                    <input type="text" name="username" class="form-control"placeholder="用户名" autocomplete="off" id="username">
                </div>
                <div class="form-group">
                    <input type="password" name="password" class="form-control" placeholder="密码" autocomplete="off" id="password">
                </div>
            </div>
            <div class="modal-footer">
                <div class="form-group">
                    <button type="button" onclick="login()" class="btn btn-primary form-control">登录</button>
                    <!--0111测试-->
<%--                    测试04666--%>
<%--                    测试05777--%>
<%--                    测试06888--%>
                </div>
                <div class="form-group">
                    <button type="button" class="btn btn-default form-control">注册</button>
<%--                    测试0111-2--%>
                </div>
            </div>
        </form>
        <!--测试036666-->
    </div><!-- /.modal-content -->
</div><!-- /.modal -->


<!-- 页脚区域 end   -->
<script src="https://cdn.jsdelivr.net/npm/jquery@3.5.1/dist/jquery.slim.min.js" integrity="sha384-DfXdz2htPH0lsSSs5nCTpuj/zy4C+OGpamoFVy38MVBnE+IbbVYUew+OrCXaRkfj" crossorigin="anonymous"></script>
<script src="https://cdn.jsdelivr.net/npm/popper.js@1.16.0/dist/umd/popper.min.js" integrity="sha384-Q6E9RHvbIyZFJoft+2mJbHaEWldlvI9IOYy5n3zV9zzTtmI3UksdQRVvoxMfooAo" crossorigin="anonymous"></script>
<script src="https://cdn.jsdelivr.net/npm/bootstrap@4.5.0/dist/js/bootstrap.min.js" integrity="sha384-OgVRvuATP1z7JjHLkuOU7Xw704+h835Lr+6QL9UvYjZE3Ipu6Tp75j7Bh/kR0JKI" crossorigin="anonymous"></script>
</body>
</body>
</html>
